home *** CD-ROM | disk | FTP | other *** search
/ InterCD 2001 November / november_2001.iso / Browsers / Netscape 6.1 / browser.xpi / bin / res / quirk.css < prev    next >
Encoding:
Cascading Style Sheet File  |  2001-06-19  |  6.7 KB  |  275 lines

  1. /*
  2.  * The contents of this file are subject to the Netscape Public
  3.  * License Version 1.1 (the "License"); you may not use this file
  4.  * except in compliance with the License. You may obtain a copy of
  5.  * the License at http://www.mozilla.org/NPL/
  6.  *
  7.  * Software distributed under the License is distributed on an "AS
  8.  * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
  9.  * implied. See the License for the specific language governing
  10.  * rights and limitations under the License.
  11.  *
  12.  * The Original Code is mozilla.org code.
  13.  *
  14.  * The Initial Developer of the Original Code is Netscape
  15.  * Communications Corporation.  Portions created by Netscape are
  16.  * Copyright (C) 1998 Netscape Communications Corporation. All
  17.  * Rights Reserved.
  18.  *
  19.  * Contributor(s): 
  20.  */
  21.  
  22. @namespace url(http://www.w3.org/1999/xhtml); /* set default namespace to HTML */
  23.  
  24. /* Quirk: input images have a blue border (b=28010) */ 
  25.  
  26. /* default border */
  27. input[type=image] {
  28.   border: 2px solid blue;
  29. }
  30.  
  31. /* border when focused -- only change style to dotted */
  32. input[type=image]:focused {
  33.   border-style: dotted;
  34. }
  35.  
  36. /* border when focused -- only change color to gray */
  37. input[type=image][disabled] {
  38.   border-color: GrayText;
  39. }
  40.  
  41.  
  42. /* Quirk: make orphaned LIs have inside bullet (b=1049) */
  43.  
  44. /* force inside position for orphaned lis */
  45. li {
  46.   list-style-position: inside; 
  47. }
  48.  
  49. /* restore outside position for lists inside LIs */
  50. li ul, li ol, li dir, li menu { 
  51.   list-style-position: outside; 
  52. }
  53.  
  54. /* undo previous two rules for properly nested lists */
  55.   ul ul,   ul ol,   ul dir,   ul menu,   ul li,
  56.   ol ul,   ol ol,   ol dir,   ol menu,   ol li,
  57.  dir ul,  dir ol,  dir dir,  dir menu,  dir li,
  58. menu ul, menu ol, menu dir, menu menu, menu li {
  59.   list-style-position: inherit;
  60. }
  61.  
  62.  
  63. /* Quirk: ensure that we get proper padding if the very first 
  64.  * node in an LI is another UL or OL. This is an ugly way to
  65.  * fix the problem, because it extends the LI up into what
  66.  * would otherwise appear to be the ULs space. (b=38832) */
  67. /* Note: this fix will fail once we implement marker box 
  68.  * alignment correctly. */
  69. li > ul:first-node,
  70. li > ol:first-node {
  71.   padding-top: 1em;
  72. }
  73.  
  74. /* Quirk: cut off all font inheritance in tables and captions except for family. */
  75. table, caption {
  76.   font-size: -moz-initial;
  77.   font-weight: -moz-initial;
  78.   font-style: -moz-initial;
  79.   font-variant: -moz-initial;
  80. }
  81.  
  82. table {
  83.   text-align: -moz-initial;
  84.   white-space: normal; /* compatible with IE & spec */
  85. }
  86.  
  87. /* Quirk: make sure backgrounds are inherited in tables */
  88. td, th, tr, thead, tbody, tfoot {
  89.   background: inherit;
  90. }
  91.  
  92. /* Quirk: collapse top margin of BODY and TD and bottom margin of TD */
  93.  
  94. /*
  95.  * While it may seem simpler to use :first-node and :last-node without
  96.  * tags, it's slower, since we have to do the :first-node or :last-node
  97.  * check on every single element in the document.  If we list all the
  98.  * element names for which the UA stylesheet specifies a margin, the
  99.  * selectors will be hashed in the RuleHash and things will be much more
  100.  * efficient.
  101.  */
  102.  
  103. body > form:first-node, td > form:first-node,
  104. body > p:first-node, td > p:first-node,
  105. body > dl:first-node, td > dl:first-node,
  106. body > multicol:first-node, td > multicol:first-node,
  107. body > blockquote:first-node, td > blockquote:first-node,
  108. body > h1:first-node, td > h1:first-node,
  109. body > h2:first-node, td > h2:first-node,
  110. body > h3:first-node, td > h3:first-node,
  111. body > h4:first-node, td > h4:first-node,
  112. body > h5:first-node, td > h5:first-node,
  113. body > h6:first-node, td > h6:first-node,
  114. body > listing:first-node, td > listing:first-node,
  115. body > plaintext:first-node, td > plaintext:first-node,
  116. body > xmp:first-node, td > xmp:first-node,
  117. body > pre:first-node, td > pre:first-node,
  118. body > ul:first-node, td > ul:first-node,
  119. body > menu:first-node, td > menu:first-node,
  120. body > dir:first-node, td > dir:first-node,
  121. body > ol:first-node, td > ol:first-node {
  122.   margin-top: 0;
  123. }
  124.  
  125. td > form:last-node,
  126. td > p:last-node,
  127. td > dl:last-node,
  128. td > multicol:last-node,
  129. td > blockquote:last-node,
  130. td > h1:last-node,
  131. td > h2:last-node,
  132. td > h3:last-node,
  133. td > h4:last-node,
  134. td > h5:last-node,
  135. td > h6:last-node,
  136. td > listing:last-node,
  137. td > plaintext:last-node,
  138. td > xmp:last-node,
  139. td > pre:last-node,
  140. td > ul:last-node,
  141. td > menu:last-node,
  142. td > dir:last-node,
  143. td > ol:last-node {
  144.   margin-bottom: 0;
  145. }
  146.  
  147.  
  148. /* Quirk: support the ways of making PRE have wrapping */
  149. pre[wrap], pre[cols], pre[width] {
  150.   white-space: -moz-pre-wrap;
  151. }
  152.  
  153.  
  154. /* Quirk: no bottom padding */
  155. input[type="text"] {
  156.   padding: 1px 0 0 0;
  157.  
  158.  
  159. /* Quirk: text inputs and textareas have special font (b=44656) */
  160. /* dealt with at the code level */
  161.  
  162.  
  163. /* Quirk: special margins for radio buttons */
  164. input[type="radio"] {
  165.   margin: 2px 5px 4px 3px;
  166.   vertical-align: bottom;
  167. }
  168.  
  169.  
  170. /* Quirk: special margins for check boxes */
  171. input[type="checkbox"] {
  172.   margin: 3px 4px 3px 3px;
  173.   vertical-align: bottom;
  174. }
  175.  
  176.  
  177. button, 
  178. input[type="reset"],
  179. input[type="button"],
  180. input[type="submit"] { 
  181.   vertical-align: bottom;
  182. }
  183.  
  184. /* Quirk: special top and bottom margins for inputs in tables */
  185.  
  186. td select[size] {
  187.   margin-top: 0px;
  188.   margin-bottom: 1px;
  189. }
  190.  
  191. td select, td select[size="1"] {
  192.   margin-top: 2px;
  193.   margin-bottom: 2px;
  194. }
  195.  
  196. td input[type="text"], input[type="password"] {
  197.   margin-top: 1px;
  198.   margin-bottom: 1px;
  199. }
  200.  
  201. td input[type="checkbox"],
  202. td input[type="radio"] {
  203.   margin-bottom: 1px;
  204. }
  205.  
  206. td textarea {
  207.   margin-top: 1px;
  208.   margin-bottom: 2px;
  209. }
  210.  
  211. /* Quirk: HRs avoid floats (b=18754) */
  212.  
  213. hr {
  214.   display: inline;
  215.   -moz-box-sizing: border-box;
  216.   margin: 0 0.1% 0 0.1%; /* Mmm! Hack-on-a-hack for bug 81776 */
  217. }
  218.  
  219. hr:before {
  220.   white-space: pre;
  221.   content: "\A";
  222. }
  223.  
  224. hr:after {
  225.   white-space: pre;
  226.   content: "\A";
  227. }
  228.  
  229. /* Quirk: DD not in DL has text-indent instead of margin (b=5119) */
  230.  
  231. :not(dl) > dd {
  232.   display: inline;
  233.   margin: 0;
  234. }
  235.  
  236. :not(dl) > dd:before {
  237.   display: inline;
  238.   white-space: pre;
  239.   font-size: 1px;
  240.   line-height: 0;
  241.   content: "\A  ";
  242.   margin-right: 40px;
  243. }
  244.  
  245. /* Quirk: MAP acts like an inline, not a block */
  246. map {
  247.   display: inline;
  248. }
  249.  
  250. /* Quirk: Make floated images have a margin  (b=58899) */
  251. img[align=left] {
  252.   margin-right: 3px;
  253. }
  254.  
  255. img[align=right] {
  256.   margin-left: 3px;
  257. }
  258.  
  259. /*
  260.  * XXX This is a potential performance problem.  This should not be
  261.  * using an attribute!
  262.  */
  263.  
  264. /* Quirk: Make sure that the residual style tags' size info. 
  265.  * does not take precedence over heading tags' size. (b=77352)
  266.  * Note: This special attribute is set only for a residual 
  267.  * style tag within a heading tag.
  268.  */
  269. *[_moz-rs-heading] { 
  270.   font-size: inherit !important; 
  271. }
  272.  
  273.  
  274.